package com.neusoft.controller;

import com.neusoft.entity.BanJi;
import com.neusoft.service.BanjiFeignService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;


/**
 * @author Administrator
 */
@RestController
@RequestMapping("banji/feign")
public class BanjiConsumerFeignController {
    @Autowired
    private BanjiFeignService banjiFeignService;

    @PostMapping("insert")
    public Object insert(BanJi bean){
        return banjiFeignService.insert(bean);
    }
    @RequestMapping("queryAll")
    public Object queryAll(){
        return banjiFeignService.queryAll();
    }
    @RequestMapping("queryById/{id}")
    public Object queryById(@PathVariable Integer id){
        return banjiFeignService.queryById(id);
    }
}
